fix: error handling — no more silent failures#28
Merged
Conversation
Critical fixes: - newRemote returns error when launcher job fails (was returning nil) - Job status polling has 10-minute timeout (was infinite loop) - Retry messages include the actual error for diagnosis - deploy create ns is idempotent (ignore AlreadyExists) Error propagation: - Helm install failure → clear error instead of cascading Route error - CRD install failure → stops deploy instead of continuing - RBAC apply failure → stops deploy - Gateway rollout timeout → clear error - GatewayAdd failure → stops deploy - ConfigMap apply in newRemote → checked before launching job - os.WriteFile for GWS credentials → checked in creds.go - os.WriteFile for client_secret.json → checked in profile.go - os.RemoveAll for staging dir → checked in newLocal Best-effort operations (intentionally unchecked, commented): - Cleanup deletes (old jobs/pods before re-create) - SCC grants (oc may not exist on non-OpenShift) - Gateway remove in teardown loop - SandboxDelete during retry cleanup Closes #22. Validated: unit 47+7, bats 29+29, podman 19+19, OCP 17/17. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The error scenarios could leave the local podman gateway selected, causing sandbox_verify to query the wrong gateway. Now explicitly selects the OCP gateway (by name pattern *-remote-*) at the start of the reuse-gateway OCP flow. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes all 16 findings from issue #22 (silent error swallowing). No more exit-0-on-failure, infinite loops, or cascading errors from unchecked operations.
Critical fixes
Error propagation added
Best-effort operations (intentionally unchecked, commented)
Test results (full matrix validated including Go + OCP)
Closes #22.